// Copyright 2025 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Code generated by sidekick. DO NOT EDIT.

#![allow(rustdoc::redundant_explicit_links)]
#![allow(rustdoc::broken_intra_doc_links)]
#![no_implicit_prelude]
extern crate bytes;
extern crate serde;
extern crate serde_json;
extern crate serde_with;
extern crate std;
extern crate wkt;

mod debug;
mod deserialize;
mod serialize;

/// **Multi-cluster Ingress**: The configuration for the MultiClusterIngress
/// feature.
#[derive(Clone, Default, PartialEq)]
#[non_exhaustive]
pub struct FeatureSpec {
    /// Fully-qualified Membership name which hosts the MultiClusterIngress CRD.
    /// Example: `projects/foo-proj/locations/global/memberships/bar`
    pub config_membership: std::string::String,

    pub(crate) _unknown_fields: serde_json::Map<std::string::String, serde_json::Value>,
}

impl FeatureSpec {
    pub fn new() -> Self {
        std::default::Default::default()
    }

    /// Sets the value of [config_membership][crate::model::FeatureSpec::config_membership].
    pub fn set_config_membership<T: std::convert::Into<std::string::String>>(
        mut self,
        v: T,
    ) -> Self {
        self.config_membership = v.into();
        self
    }
}

impl wkt::message::Message for FeatureSpec {
    fn typename() -> &'static str {
        "type.googleapis.com/google.cloud.gkehub.multiclusteringress.v1.FeatureSpec"
    }
}
